package com.xc.ezplan.admin.vo;

import java.util.List;
import java.util.Set;

import com.alibaba.fastjson.annotation.JSONField;
import com.xc.ezplan.admin.entity.AdminMenu;
import com.xc.ezplan.admin.entity.AdminRole;
import com.xc.ezplan.core.base.BaseVo;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * @author lixingchen
 * @date 2022/11/20
 * @description 后台菜单VO
 */
@Data
@EqualsAndHashCode(callSuper = true)
public class AdminMenuVo extends BaseVo {

	@ApiModelProperty(value = "ID", hidden = true)
	private Long id;

	@ApiModelProperty(value = "上级菜单ID")
	private Long pid;

	@JSONField(serialize = false)
	@ApiModelProperty(value = "菜单角色")
	private Set<AdminRole> roles;

	@ApiModelProperty(value = "菜单标题")
	private String title;

	@ApiModelProperty(value = "菜单组件名称")
	private String componentName;

	@ApiModelProperty(value = "排序")
	private Integer menuSort = 999;

	@ApiModelProperty(value = "组件路径")
	private String component;

	@ApiModelProperty(value = "路由地址")
	private String path;

	@ApiModelProperty(value = "菜单类型，目录、菜单、按钮")
	private Integer type;

	@ApiModelProperty(value = "权限标识")
	private String permission;

	@ApiModelProperty(value = "菜单图标")
	private String icon;

	@ApiModelProperty(value = "缓存")
	private Boolean cache;

	@ApiModelProperty(value = "是否隐藏")
	private Boolean hidden;

	@ApiModelProperty(value = "外链菜单")
	private Boolean iFrame;

	@ApiModelProperty(value = "菜单列表")
	private List<AdminMenu> menuList;

}
